package com.example.demo.Service;

import com.example.demo.mapper.BlacklistMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.stereotype.Service;

@Service
public class BlacklistService {

    @Autowired
    private BlacklistMapper mapper;
    //黑名单权限
    public boolean selectlist(String id)
    {
        return mapper.selectlist(id) != 1;
    }
    //管理员权限
    public boolean selectrole(String id)
    {
        return mapper.selectrole(id) == 1;
    }
    public void insertUser(String id)
    {
        mapper.insertUser(id);
    }

}
